package com.qiye.pointsserver.model.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.time.LocalDate;
import java.time.LocalDateTime;

import jakarta.persistence.Entity;
import jakarta.persistence.Id;
import lombok.Data;

/**
 * 用户信息表
 * @TableName sys_userinfo
 */
@TableName(value ="sys_userinfo")
@Data
@Entity
public class Userinfo implements Serializable {
    /**
     * 主键ID
     */
    @Id
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * 用户ID 外键与sys_user表关联
     */
    @TableField(value = "user_id")
    private Integer userId;

    /**
     * 姓名
     */
    @TableField(value = "name")
    private String name;

    /**
     * 联系方式
     */
    @TableField(value = "phone")
    private String phone;

    /**
     * 所属公司
     */
    @TableField(value = "company")
    private String company;

    /**
     * 性别：0未知，1男，2女
     */
    @TableField(value = "gender")
    private Integer gender;

    /**
     * 生日
     */
    @TableField(value = "birthdate")
    private LocalDate birthdate;

    /**
     * 创建时间
     */
    @TableField(value = "create_time")
    private LocalDateTime createTime;

    /**
     * 修改时间
     */
    @TableField(value = "update_time")
    private LocalDateTime updateTime;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}